package com.jms.web.mapper;

import com.jms.web.pojo.Tea;
import org.apache.ibatis.annotations.*;
import org.apache.ibatis.session.RowBounds;

import java.util.List;

public interface TeaMapper {


//    @Select("select * from tea")
    List<Tea> selectAll();

//    @Insert("insert into tea values(#{id},#{tea_name},#{teatypeid},#{ordered},#{description},#{status})")
    Integer insert(Tea tea);

//    @Update("update tea set tea_name = #{tea_name},teatypeid = #{teatypeid},ordered = #{ordered},description = #{description},status = #{status}\n" +
//            "            where id = #{id} ")
    Integer update(Tea tea);

//    @Delete("delete from tea where id = #{id}")
    Integer delete(Integer id);

    List<Tea> selectByTea(Tea tea);
    List<Tea> selectByTeaIds(List<Integer> id);

    @Select("SELECT * FROM tea")
    List<Tea> selectAll02(RowBounds rowBounds);
}
